home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Trusted Irix /B 4.0.4
/
Trusted-Irix B-4.0.1.iso
/
dist
/
eoe1.idb
/
usr
/
include
/
sys
/
sysinfo.h.z
/
sysinfo.h
Wrap
C/C++ Source or Header
|
1992-04-03
|
7KB
|
211 lines
/* Copyright (c) 1984 AT&T */
/* All Rights Reserved */
/* THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF AT&T */
/* The copyright notice above does not evidence any */
/* actual or intended publication of such source code. */
#ifndef __SYS_SYSINFO_H__
#define __SYS_SYSINFO_H__
#ident "$Revision: 3.12 $"
#include "sys/sema.h"
/*
* System Information.
*/
struct sysinfo {
time_t cpu[6];
#define CPU_IDLE 0
#define CPU_USER 1
#define CPU_KERNEL 2
#define CPU_WAIT 3
#define CPU_SXBRK 4
#define CPU_INTR 5
time_t wait[5];
#define W_IO 0
#define W_SWAP 1
#define W_PIO 2
#define W_GFXC 3
#define W_GFXF 4
unsigned long bread;
unsigned long bwrite;
unsigned long lread;
unsigned long lwrite;
unsigned long phread;
unsigned long phwrite;
unsigned long swapin;
unsigned long swapout;
unsigned long bswapin;
unsigned long bswapout;
unsigned long pswapout;
unsigned long pswitch;
unsigned long syscall;
unsigned long remcall; /* REMOTE: remote call */
unsigned long fileop; /* REMOTE: remote fileop */
unsigned long serve; /* REMOTE: remote server */
unsigned long sysread;
unsigned long syswrite;
unsigned long sysfork;
unsigned long sysexec;
unsigned long runque;
unsigned long runocc;
unsigned long swpque;
unsigned long swpocc;
unsigned long iget;
unsigned long namei;
unsigned long dirblk;
unsigned long readch;
unsigned long writech;
unsigned long rcvint;
unsigned long xmtint;
unsigned long mdmint;
unsigned long rawch;
unsigned long canch;
unsigned long outch;
unsigned long msg;
unsigned long sema;
unsigned long pnpfault;
unsigned long wrtfault;
unsigned long ptc; /* pty controller character count */
unsigned long pts; /* pty slave character count */
unsigned long gswitch; /* # of graphics context switches */
unsigned long gintr; /* # of gm interrupts */
unsigned long gswapbuf; /* # of swap buffers calls */
unsigned long griioctl; /* # of griioctl calls */
unsigned long fifowait; /* fifo interrupts that block */
unsigned long fifonowait; /* fifo interrupts that don't block */
unsigned long intr_svcd; /* interrupts serviced */
unsigned long vmeintr_svcd; /* vme interrupts serviced */
};
extern struct sysinfo sysinfo;
struct syswait {
sema_t iowait;
sema_t swap;
sema_t physio;
};
struct dinfo {
/* ELEMENT FOR sar -Du */
time_t serve; /* ticks in serve() since boot */
/* ELEMENTS FOR sar -Dc */
unsigned long isyscall; /* # of incoming syscalls since boot */
unsigned long isysread; /* # of incoming read's since boot */
unsigned long ireadch; /* char's read by incoming read's */
unsigned long isyswrite; /* # of incoming write's since boot */
unsigned long iwritech; /* char's written by incoming writes */
unsigned long isysexec; /* # of incoming exec's since boot */
unsigned long osyscall; /* # of outgoing syscalls since boot */
unsigned long osysread; /* # of outgoing read's since boot */
unsigned long oreadch; /* char's read by outgoing read's */
unsigned long osyswrite; /* # of outgoing write's since boot */
unsigned long owritech; /* char's written by outgoing writes */
unsigned long osysexec; /* # of outgoing exec's since boot */
/* ELEMENTS FOR sar -S*/
unsigned long nservers; /* sum of all servers since boot */
unsigned long srv_que; /* sum of server Q lgth since boot */
unsigned long srv_occ; /* ticks server Q found occupied */
unsigned long rcv_que; /* sum of receive Q lgth since boot */
unsigned long rcv_occ; /* clock ticks receive Q occupied */
};
struct rcinfo {
unsigned long cbread; /* read blocks sent to remote server*/
/* (not found in cache) */
unsigned long cbwrite; /* write blocks not found in local cache*/
unsigned long clread; /* total blocks in remote read */
unsigned long clwrite; /* total blocks in remote write */
unsigned long snd_dis; /* cache disable messages sent (server) */
unsigned long snd_msg; /* total RFS messages sent */
unsigned long rcv_dis; /* cache disable messages received (client) */
unsigned long rcv_msg; /* total RFS messages received */
unsigned long dis_bread; /* # of per-file blocks flushed from cache*/
unsigned long blk_inval; /* # of per-file blocks flushed from cache*/
unsigned long inval; /* # of per-file cache flushes */
};
extern struct dinfo dinfo;
extern struct rcinfo rcinfo;
extern int minserve; /* DU tunable: sever low water mark */
extern int maxserve; /* DU tunable: sever high water mark */
extern int nservers; /* total servers in system */
extern int idleserver; /* idle servers in system */
extern int msglistcnt; /* receive descriptors in msg queue */
struct minfo {
unsigned long freemem[2]; /* freemem in pages */
/* "double" unsigned long format*/
/* freemem[0] least significant */
unsigned long freeswap; /* free swap space */
unsigned long vfault; /* translation fault */
unsigned long demand; /* demand zero and demand fill pages */
unsigned long swap; /* pages on swap */
unsigned long cache; /* pages in cache */
unsigned long file; /* pages on file */
unsigned long pfault; /* protection fault */
unsigned long cw; /* copy on write */
unsigned long steal; /* steal the page */
unsigned long freedpgs; /* pages are freed */
unsigned long unmodsw; /* getpages finds unmodified pages */
/* on swap */
unsigned long unmodfl; /* getpages finds unmodified pages */
/* in file */
unsigned long tlbpids; /* new tlbpids assigned */
unsigned long tfault; /* double tlb miss */
unsigned long rfault; /* reference bit vfault */
unsigned long tlbflush; /* entire tlb flushed on a processor */
unsigned long tlbsync; /* site-wide tlb flushes */
unsigned long tvirt; /* flush caused by virtual address */
/* depletion */
unsigned long tphys; /* tlb invalidation caused by */
/* changing virt/phys association */
unsigned long twrap; /* flush caused by tlbpid wrap */
unsigned long tdirt; /* tlbs marked stale for process */
/* on another processor (MP only) */
unsigned long heapmem; /* total memory allocated to heap */
unsigned long halloc[2]; /* heap-malloc in bytes */
/* "double" unsigned long format*/
unsigned long hrnd[2]; /* heap-malloc roundings in bytes */
unsigned long hfree[2]; /* heap-malloc frees in bytes */
unsigned long hovhd; /* heap headers and such */
unsigned long hunused; /* unallocated heap blocks */
unsigned long hreq[2]; /* requests to kern malloc */
unsigned long hnblks[2]; /* blocks searched per request */
};
#ifdef _KERNEL
extern struct minfo minfo;
extern struct syswait syswait;
struct syserr {
unsigned long inodeovf;
unsigned long fileovf;
unsigned long textovf;
unsigned long procovf;
};
/* ksa must come after syserr */
#include "sys/ksa.h"
extern struct syserr syserr;
struct shlbinfo {
unsigned long shlbs; /* Max # of libs a process can link in */
/* at one time. */
unsigned long shlblnks;/* # of times processes that have used */
/* static shared libraries. */
unsigned long shlbovf;/* # of processes needed more shlibs */
/* than the system imposed limit. */
unsigned long shlbatts;/* # of times processes have attached */
/* run time libraries. */
};
extern struct shlbinfo shlbinfo;
#endif /* _KERNEL */
#endif /* __SYS_SYSINFO_H__ */